package org.zhadoop.stream.cql.semanticanalyzer.parser.visitor;

import org.zhadoop.stream.cql.semanticanalyzer.parser.CQLParser.ExpressionContext;
import org.zhadoop.stream.cql.semanticanalyzer.parser.context.ExpressionWithLaparenContext;

/**
 * 带括号的表达式的语法遍历
 * @author zwd
 *
 */
public class ExpressionWithLaparenVisitor extends AbsCQLParserBaseVisitor<ExpressionWithLaparenContext>{

	private ExpressionWithLaparenContext context = null;
	
	public ExpressionWithLaparenVisitor() {
		context = new ExpressionWithLaparenContext();
	}
	
	@Override
	protected ExpressionWithLaparenContext defaultResult() {
		return context;
	}
	
	@Override
	public ExpressionWithLaparenContext visitExpression(ExpressionContext ctx) {
		ExpressionVisitor visitor = new ExpressionVisitor();
        context.setExpression(visitor.visit(ctx));
        return context;
	}
}
